package com.deyuanyun.pic.pig.controller.vo;

import com.deyuanyun.pic.common.util.DateUtil;
import com.deyuanyun.pic.common.util.StringUtils;
import com.deyuanyun.pic.settings.support.biz.CodeUtil;

import java.math.BigDecimal;
import java.util.Date;

public class FromPigVO {
	//发球点Id
	private String id;
	//发球点名称
	private String pipeValName;
	//任务名称
	private String taskName;
	//清管类型
	private String pagType;
	//检测器类型
	private String detectorType;
	//清管器类型(编辑框)
	private String pigType;
	//清管工具
	private String pagTool;
	//与上一次清管间隔
	private Integer lastLimitDays;
	//发球筒编号
	private String pigNumber;
	//发球筒发球时间
	private Date sendBallsTime;
	//发球记录时间
	private Date recordTime;
	//发球筒绝对距离
	private Double mileage;
	//发球筒最近参考点
	private String reference;
	//发球筒相对最近参考点距离
	private Double referencedistance;
	//发球筒gisid
	private String gisId;
	//发球到达人
	private String arriveUser;
	//发球筒记录人
	private String recrder;
	//发球筒发球出站压力
	private Double ballsPressureFrom;
	//发球筒收球进站压力
	private Double ballsPressureTo;
	//发球筒流量
	private Double ballsFlow;
	//发球管道内径（mm）
	private Double interDiameter;
	//发球筒发球压差
	private Double pressure;
	//发球筒过盈量
	private Double interference;
	//发球点描述
	private String remark;
	//对应的发球记录表ID
	private String sendId;
	//是否通过 --通过为Y 未通过为N
	private String state;

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getPipeValName() {
		return pipeValName;
	}

	public void setPipeValName(String pipeValName) {
		this.pipeValName = pipeValName;
	}

	public String getTaskName() {
		return taskName;
	}

	public void setTaskName(String taskName) {
		this.taskName = taskName;
	}

	public String getPagType() {
		return  CodeUtil.getName(pagType);
	}

	public void setPagType(String pagType) {
		this.pagType = pagType;
	}

	public String getDetectorType() {
		return CodeUtil.getName(detectorType);
	}

	public void setDetectorType(String detectorType) {
		this.detectorType = detectorType;
	}

	public String getPigType() {
		return pigType;
	}

	public void setPigType(String pigType) {
		this.pigType = pigType;
	}

	public String getPagTool() {
		return StringUtils.isNotNullEmpty(this.getDetectorType())?this.getDetectorType():this.pigType;
	}

	public void setPagTool(String pagTool) {
		this.pagTool = pagTool;
	}

	public Integer getLastLimitDays() {
		return lastLimitDays;
	}

	public void setLastLimitDays(Integer lastLimitDays) {
		this.lastLimitDays = lastLimitDays;
	}

	public String getPigNumber() {
		return pigNumber;
	}

	public void setPigNumber(String pigNumber) {
		this.pigNumber = pigNumber;
	}

	public String getArriveUser() {
		return arriveUser;
	}

	public void setArriveUser(String arriveUser) {
		this.arriveUser = arriveUser;
	}

	public Date getSendBallsTime() {
		return sendBallsTime;
	}

	public void setSendBallsTime(Date sendBallsTime) {
		this.sendBallsTime = sendBallsTime;
	}

	public Date getRecordTime() {
		return recordTime;
	}

	public void setRecordTime(Date recordTime) {
		this.recordTime = recordTime;
	}

	public Double getMileage() {
		return mileage;
	}

	public void setMileage(Double mileage) {
		this.mileage = mileage;
	}

	public String getReference() {
		return reference;
	}

	public void setReference(String reference) {
		this.reference = reference;
	}

	public Double getReferencedistance() {
		return StringUtils.isNotNullEmpty(this.getReference())?referencedistance:null;
	}

	public void setReferencedistance(Double referencedistance) {
		this.referencedistance = referencedistance;
	}

	public String getGisId() {
		return gisId;
	}

	public void setGisId(String gisId) {
		this.gisId = gisId;
	}

	public String getRecrder() {
		return recrder;
	}

	public void setRecrder(String recrder) {
		this.recrder = recrder;
	}

	public Double getBallsPressureFrom() {
		return ballsPressureFrom;
	}

	public void setBallsPressureFrom(Double ballsPressureFrom) {
		this.ballsPressureFrom = ballsPressureFrom;
	}

	public Double getBallsPressureTo() {
		return ballsPressureTo;
	}

	public void setBallsPressureTo(Double ballsPressureTo) {
		this.ballsPressureTo = ballsPressureTo;
	}

	public Double getBallsFlow() {
		return ballsFlow;
	}

	public void setBallsFlow(Double ballsFlow) {
		this.ballsFlow = ballsFlow;
	}

	public Double getInterDiameter() {
		return interDiameter;
	}

	public void setInterDiameter(Double interDiameter) {
		this.interDiameter = interDiameter;
	}

	public Double getPressure() {
		return pressure;
	}

	public void setPressure(Double pressure) {
		this.pressure = pressure;
	}

	public Double getInterference() {
		return interference;
	}

	public void setInterference(Double interference) {
		this.interference = interference;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public String getSendId() {
		return sendId;
	}

	public void setSendId(String sendId) {
		this.sendId = sendId;
	}

	public String getState() {
		return DateUtil.isNotNull(this.sendBallsTime) ? "Y" : "N";
	}
}
